import { connect } from 'react-redux';
import { actions } from './store';
function Counter(props) {
    const {number,increment,decrement} = props;
    return (
        <div>
            <p>{number}</p>
            <button onClick={()=>increment()}>+</button>
            <button onClick={()=>decrement()}>-</button>
        </div>
    )
}
export default connect(
    state => state.counter,
    actions
)(Counter);
//cra toolkit